package com.tqjc.system.common.enums;

import lombok.AllArgsConstructor;
import lombok.Getter;
import lombok.NoArgsConstructor;

/**
 * @description:
 * @Author: 86195
 * @Date: 2024/1/8 16:01
 **/
@NoArgsConstructor
@AllArgsConstructor
@Getter
public enum ScannerInfoEnum {

    SCANNER_SINGLE(1,"宽轨槽车扫描仪",0,null),

    SCANNER_DOUBLE(2,"双轨槽车扫描仪",0,null),

    SCANNER_DREGS_STEEL_AREA_1(3,"渣钢1库区扫描仪",1,"B1"),

    SCANNER_DREGS_STEEL_AREA_2(3,"渣钢2库区扫描仪",1,"B2"),

    SCANNER_WASTE_STEEL_AREA_1(3,"废钢1库区扫描仪",1,"A1"),

    SCANNER_WASTE_STEEL_AREA_2(3,"废钢2库区扫描仪",1,"A2");


    /**
     * 槽车扫描类型
     */
    private int scannerType;

    /**
     * 描述
     */
    private String desc;

    /**
     * 定时任务类型   0:槽车扫描仪定时任务触发   1：库区扫描仪定时任务触发
     */
    private int taskType;

    private String redisTag;

    public static String getRedisTag(String desc){
        for (ScannerInfoEnum value : ScannerInfoEnum.values()) {
            if(value.getDesc().equals(desc)){
                return value.getRedisTag();
            }
        }

        return null;
    }

}
